home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 26 / Cream of the Crop 26.iso / os2 / octa209s.zip / octave-2.09 / BUGS next >
Text File  |  1997-05-28  |  15KB  |  359 lines

  1. This file documents known bugs in Octave and describes where and how to
  2. report any bugs that you may find.
  3.  
  4.    Copyright (C) 1996, 1997 John W. Eaton.  You may copy, distribute,
  5. and modify it freely as long as you preserve this copyright notice and
  6. permission notice.
  7.  
  8. Known Causes of Trouble with Octave
  9. ***********************************
  10.  
  11.    This section describes known problems that affect users of Octave.
  12. Most of these are not Octave bugs per se--if they were, we would fix
  13. them.  But the result for a user may be like the result of a bug.
  14.  
  15.    Some of these problems are due to bugs in other software, some are
  16. missing features that are too much work to add, and some are places
  17. where people's opinions differ as to what is best.
  18.  
  19. Actual Bugs We Haven't Fixed Yet
  20. ================================
  21.  
  22.    * Output that comes directly from Fortran functions is not sent
  23.      through the pager and may appear out of sequence with other output
  24.      that is sent through the pager.  One way to avoid this is to force
  25.      pending output to be flushed before calling a function that will
  26.      produce output from within Fortran functions.  To do this, use the
  27.      command
  28.  
  29.           fflush (stdout)
  30.  
  31.      Another possible workaround is to use the command
  32.  
  33.           page_screen_output = "false"
  34.  
  35.      to turn the pager off.
  36.  
  37.    * If you get messages like
  38.  
  39.           Input line too long
  40.  
  41.      when trying to plot many lines on one graph, you have probably
  42.      generated a plot command that is too larger for `gnuplot''s
  43.      fixed-length buffer for commands.  Splitting up the plot command
  44.      doesn't help because replot is implemented in gnuplot by simply
  45.      appending the new plotting commands to the old command line and
  46.      then evaluating it again.
  47.  
  48.      You can demonstrate this `feature' by running gnuplot and doing
  49.      something like
  50.  
  51.             plot sin (x), sin (x), sin (x), ... lots more ..., sin (x)
  52.  
  53.      and then
  54.  
  55.             replot sin (x), sin (x), sin (x), ... lots more ..., sin (x)
  56.  
  57.      after repeating the replot command a few times, gnuplot will give
  58.      you an error.
  59.  
  60.      Also, it doesn't help to use backslashes to enter a plot command
  61.      over several lines, because the limit is on the overall command
  62.      line length, once the backslashed lines are all pasted together.
  63.  
  64.      Because of this, Octave tries to use as little of the command-line
  65.      length as possible by using the shortest possible abbreviations for
  66.      all the plot commands and options.  Unfortunately, the length of
  67.      the temporary file names is probably what is taking up the most
  68.      space on the command line.
  69.  
  70.      You can buy a little bit of command line space by setting the
  71.      environment variable `TMPDIR' to be "." before starting Octave, or
  72.      you can increase the maximum command line length in gnuplot by
  73.      changing the following limits in the file plot.h in the gnuplot
  74.      distribution and recompiling gnuplot.
  75.  
  76.           #define MAX_LINE_LEN 32768  /* originally 1024 */
  77.           #define MAX_TOKENS 8192     /* originally 400 */
  78.  
  79.      Of course, this doesn't really fix the problem, but it does make it
  80.      much less likely that you will run into trouble unless you are
  81.      putting a very large number of lines on a given plot.
  82.  
  83.    A list of ideas for future enhancements is distributed with Octave.
  84. See the file `PROJECTS' in the top level directory in the source
  85. distribution.
  86.  
  87. Reporting Bugs
  88. ==============
  89.  
  90.    Your bug reports play an essential role in making Octave reliable.
  91.  
  92.    When you encounter a problem, the first thing to do is to see if it
  93. is already known.  *Note Trouble::.  If it isn't known, then you should
  94. report the problem.
  95.  
  96.    Reporting a bug may help you by bringing a solution to your problem,
  97. or it may not.  In any case, the principal function of a bug report is
  98. to help the entire community by making the next version of Octave work
  99. better.  Bug reports are your contribution to the maintenance of Octave.
  100.  
  101.    In order for a bug report to serve its purpose, you must include the
  102. information that makes it possible to fix the bug.
  103.  
  104.    If you have Octave working at all, the easiest way to prepare a
  105. complete bug report is to use the Octave function `bug_report'.  When
  106. you execute this function, Octave will prompt you for a subject and then
  107. invoke the editor on a file that already contains all the configuration
  108. information.  When you exit the editor, Octave will mail the bug report
  109. for you.
  110.  
  111. Have You Found a Bug?
  112. =====================
  113.  
  114.    If you are not sure whether you have found a bug, here are some
  115. guidelines:
  116.  
  117.    * If Octave gets a fatal signal, for any input whatever, that is a
  118.      bug.  Reliable interpreters never crash.
  119.  
  120.    * If Octave produces incorrect results, for any input whatever, that
  121.      is a bug.
  122.  
  123.    * Some output may appear to be incorrect when it is in fact due to a
  124.      program whose behavior is undefined, which happened by chance to
  125.      give the desired results on another system.  For example, the
  126.      range operator may produce different results because of
  127.      differences in the way floating point arithmetic is handled on
  128.      various systems.
  129.  
  130.    * If Octave produces an error message for valid input, that is a bug.
  131.  
  132.    * If Octave does not produce an error message for invalid input,
  133.      that is a bug.  However, you should note that your idea of
  134.      "invalid input" might be my idea of "an extension" or "support for
  135.      traditional practice".
  136.  
  137.    * If you are an experienced user of programs like Octave, your
  138.      suggestions for improvement are welcome in any case.
  139.  
  140. Where to Report Bugs
  141. ====================
  142.  
  143.    If you have Octave working at all, the easiest way to prepare a
  144. complete bug report is to use the Octave function `bug_report'.  When
  145. you execute this function, Octave will prompt you for a subject and then
  146. invoke the editor on a file that already contains all the configuration
  147. information.  When you exit the editor, Octave will mail the bug report
  148. for you.
  149.  
  150.    If for some reason you cannot use Octave's `bug_report' function,
  151. send bug reports for Octave to <bug-octave@bevo.che.wisc.edu>.
  152.  
  153.    *Do not send bug reports to `help-octave'*.  Most users of Octave do
  154. not want to receive bug reports.  Those that do have asked to be on the
  155. mailing list.
  156.  
  157.    As a last resort, send bug reports on paper to:
  158.  
  159.      Octave Bugs c/o John W. Eaton
  160.      University of Wisconsin-Madison
  161.      Department of Chemical Engineering
  162.      1415 Engineering Drive
  163.      Madison, Wisconsin 53706  USA
  164.  
  165. How to Report Bugs
  166. ==================
  167.  
  168.    Send bug reports for Octave to one of the addresses listed in *Note
  169. Bug Lists::.
  170.  
  171.    The fundamental principle of reporting bugs usefully is this:
  172. *report all the facts*.  If you are not sure whether to state a fact or
  173. leave it out, state it!
  174.  
  175.    Often people omit facts because they think they know what causes the
  176. problem and they conclude that some details don't matter.  Thus, you
  177. might assume that the name of the variable you use in an example does
  178. not matter.  Well, probably it doesn't, but one cannot be sure.
  179. Perhaps the bug is a stray memory reference which happens to fetch from
  180. the location where that name is stored in memory; perhaps, if the name
  181. were different, the contents of that location would fool the
  182. interpreter into doing the right thing despite the bug.  Play it safe
  183. and give a specific, complete example.
  184.  
  185.    Keep in mind that the purpose of a bug report is to enable someone to
  186. fix the bug if it is not known. Always write your bug reports on the
  187. assumption that the bug is not known.
  188.  
  189.    Sometimes people give a few sketchy facts and ask, "Does this ring a
  190. bell?"  This cannot help us fix a bug.  It is better to send a complete
  191. bug report to begin with.
  192.  
  193.    Try to make your bug report self-contained.  If we have to ask you
  194. for more information, it is best if you include all the previous
  195. information in your response, as well as the information that was
  196. missing.
  197.  
  198.    To enable someone to investigate the bug, you should include all
  199. these things:
  200.  
  201.    * The version of Octave.  You can get this by noting the version
  202.      number that is printed when Octave starts, or running it with the
  203.      `-v' option.
  204.  
  205.    * A complete input file that will reproduce the bug.
  206.  
  207.      A single statement may not be enough of an example--the bug might
  208.      depend on other details that are missing from the single statement
  209.      where the error finally occurs.
  210.  
  211.    * The command arguments you gave Octave to execute that example and
  212.      observe the bug.  To guarantee you won't omit something important,
  213.      list all the options.
  214.  
  215.      If we were to try to guess the arguments, we would probably guess
  216.      wrong and then we would not encounter the bug.
  217.  
  218.    * The type of machine you are using, and the operating system name
  219.      and version number.
  220.  
  221.    * The command-line arguments you gave to the `configure' command when
  222.      you installed the interpreter.
  223.  
  224.    * A complete list of any modifications you have made to the
  225.      interpreter source.
  226.  
  227.      Be precise about these changes--show a context diff for them.
  228.  
  229.    * Details of any other deviations from the standard procedure for
  230.      installing Octave.
  231.  
  232.    * A description of what behavior you observe that you believe is
  233.      incorrect.  For example, "The interpreter gets a fatal signal,"
  234.      or, "The output produced at line 208 is incorrect."
  235.  
  236.      Of course, if the bug is that the interpreter gets a fatal signal,
  237.      then one can't miss it.  But if the bug is incorrect output, we
  238.      might not notice unless it is glaringly wrong.
  239.  
  240.      Even if the problem you experience is a fatal signal, you should
  241.      still say so explicitly.  Suppose something strange is going on,
  242.      such as, your copy of the interpreter is out of synch, or you have
  243.      encountered a bug in the C library on your system.  Your copy
  244.      might crash and the copy here would not.  If you said to expect a
  245.      crash, then when the interpreter here fails to crash, we would
  246.      know that the bug was not happening.  If you don't say to expect a
  247.      crash, then we would not know whether the bug was happening.  We
  248.      would not be able to draw any conclusion from our observations.
  249.  
  250.      Often the observed symptom is incorrect output when your program
  251.      is run.  Unfortunately, this is not enough information unless the
  252.      program is short and simple.  It is very helpful if you can
  253.      include an explanation of the expected output, and why the actual
  254.      output is incorrect.
  255.  
  256.    * If you wish to suggest changes to the Octave source, send them as
  257.      context diffs.  If you even discuss something in the Octave source,
  258.      refer to it by context, not by line number, because the line
  259.      numbers in the development sources probably won't match those in
  260.      your sources.
  261.  
  262.    Here are some things that are not necessary:
  263.  
  264.    * A description of the envelope of the bug.
  265.  
  266.      Often people who encounter a bug spend a lot of time investigating
  267.      which changes to the input file will make the bug go away and
  268.      which changes will not affect it.  Such information is usually not
  269.      necessary to enable us to fix bugs in Octave, but if you can find
  270.      a simpler example to report *instead* of the original one, that is
  271.      a convenience.  Errors in the output will be easier to spot,
  272.      running under the debugger will take less time, etc. Most Octave
  273.      bugs involve just one function, so the most straightforward way to
  274.      simplify an example is to delete all the function definitions
  275.      except the one in which the bug occurs.
  276.  
  277.      However, simplification is not vital; if you don't want to do
  278.      this, report the bug anyway and send the entire test case you used.
  279.  
  280.    * A patch for the bug.  Patches can be helpful, but if you find a
  281.      bug, you should report it, even if you cannot send a fix for the
  282.      problem.
  283.  
  284. Sending Patches for Octave
  285. ==========================
  286.  
  287.    If you would like to write bug fixes or improvements for Octave,
  288. that is very helpful.  When you send your changes, please follow these
  289. guidelines to avoid causing extra work for us in studying the patches.
  290.  
  291.    If you don't follow these guidelines, your information might still be
  292. useful, but using it will take extra work.  Maintaining Octave is a lot
  293. of work in the best of circumstances, and we can't keep up unless you do
  294. your best to help.
  295.  
  296.    * Send an explanation with your changes of what problem they fix or
  297.      what improvement they bring about.  For a bug fix, just include a
  298.      copy of the bug report, and explain why the change fixes the bug.
  299.  
  300.    * Always include a proper bug report for the problem you think you
  301.      have fixed.  We need to convince ourselves that the change is
  302.      right before installing it.  Even if it is right, we might have
  303.      trouble judging it if we don't have a way to reproduce the problem.
  304.  
  305.    * Include all the comments that are appropriate to help people
  306.      reading the source in the future understand why this change was
  307.      needed.
  308.  
  309.    * Don't mix together changes made for different reasons.  Send them
  310.      *individually*.
  311.  
  312.      If you make two changes for separate reasons, then we might not
  313.      want to install them both.  We might want to install just one.
  314.  
  315.    * Use `diff -c' to make your diffs.  Diffs without context are hard
  316.      for us to install reliably.  More than that, they make it hard for
  317.      us to study the diffs to decide whether we want to install them.
  318.      Unidiff format is better than contextless diffs, but not as easy
  319.      to read as `-c' format.
  320.  
  321.      If you have GNU diff, use `diff -cp', which shows the name of the
  322.      function that each change occurs in.
  323.  
  324.    * Write the change log entries for your changes.
  325.  
  326.      Read the `ChangeLog' file to see what sorts of information to put
  327.      in, and to learn the style that we use.  The purpose of the change
  328.      log is to show people where to find what was changed.  So you need
  329.      to be specific about what functions you changed; in large
  330.      functions, it's often helpful to indicate where within the
  331.      function the change was made.
  332.  
  333.      On the other hand, once you have shown people where to find the
  334.      change, you need not explain its purpose. Thus, if you add a new
  335.      function, all you need to say about it is that it is new.  If you
  336.      feel that the purpose needs explaining, it probably does--but the
  337.      explanation will be much more useful if you put it in comments in
  338.      the code.
  339.  
  340.      If you would like your name to appear in the header line for who
  341.      made the change, send us the header line.
  342.  
  343. How To Get Help with Octave
  344. ===========================
  345.  
  346.    The mailing list <help-octave@bevo.che.wisc.edu> exists for the
  347. discussion of matters related to using and installing Octave.  If would
  348. like to join the discussion, please send a short note to
  349. <help-octave*-request*@bevo.che.wisc.edu>.
  350.  
  351.    *Please do not* send requests to be added or removed from the the
  352. mailing list, or other administrative trivia to the list itself.
  353.  
  354.    If you think you have found a bug in the installation procedure,
  355. however, you should send a complete bug report for the problem to
  356. <bug-octave@bevo.che.wisc.edu>.  *Note Bug Reporting:: for information
  357. that will help you to submit a useful report.
  358.  
  359.